<%@ page language="java" contentType="text/html;charset=utf-8" pageEncoding="utf-8"%>

<!DOCTYPE html>
<html>
  <head>
	<%@ include file="/WEB-INF/backstage/base.jsp" %>
    
    <title>SWIFT4J快速开发平台</title>
    
    <style type="text/css">
    	p  {list-style:none;}
    	
    	p a {
    		font-size: 18px;
		    padding-top:5px;
			text-decoration:none;
			color:#15428b;
			font: normal verdana;
			font-weight:bold;
			letter-spacing: 5px;
			line-height:25px;
    	}
    	
    	p a:hover {
			font-size: 20px;
			color:#88428b;
		}
    </style>
    
    <script type="text/javascript">
    	$(function() {
    		$('#navigator a').dblclick(function() {
    			//相同ID的TAB只能打开一个
    			if($('#mainTabs').tabs('getTab',this.innerText) != null) {
    				$('#mainTabs').tabs('select',this.innerText);
    				return;
    			}
    			$('#mainTabs').tabs('add',{
    				id : $(this).attr('projectNo'),
    				title:this.innerText,
					closable:true, 
					fit: true,
					border: false,
					content:'<iframe scrolling="no" frameborder="0" width="100%" height="100%" src="'
	                	  + __SHOWMAINVIEW 
	                	  + '_mduno=' + $(this).attr('moduleNo')
	                	  + '"></iframe>' 
    			});
    			
    			//$('#navigator').accordion('select','档案管理');
    		});
    	});
    </script>
  </head>

	<body class="easyui-layout">

		<div data-options="region:'north'" style="height: 78px;">
			<div style="float:right; padding-right: 50px; margin-top: 50px;">
				<a href="<%=bp %>managerLogin/logout.do" class="easyui-linkbutton" data-options="iconCls:'icon-man',plain:true">退出登录</a>
			</div>
		</div>

		<div data-options="region:'west',split:true" style="width: 250px;">
			<div id="tt" class="easyui-tabs" style="width:220px;" data-options="fit:true, border:false"> 
				<div title="功能导航">
					<div class="easyui-panel" data-options="fit:true, border:false" style="padding-top: 2px">
						<div id="navigator" class="easyui-accordion" data-options="fit:true, border:false">
							<s:iterator value="#request.projectTree">
								<div title='<s:property value="projectName"/>' data-options="iconCls:'icon-save'<s:if test="%{projectName == '档案管理'}">,selected:true</s:if>" style="overflow:auto;text-align: center;">
									<s:iterator value="children" id="children"> 
										<p><a href="javascript:void(0)" moduleNo="<s:property value='#children.module.moduleNo'/>"><s:property value="#children.projectName"/></a></p>
									</s:iterator>
								</div> 
							</s:iterator>
						</div>
					</div>
				</div>
				<!-- 
				<div title="快速打开">
					fdsa
				</div>
				 -->
			</div>
		</div>

		<div data-options="region:'center'" style="background: #eee;">
			<div id="mainTabs" class="easyui-tabs" style="width:220px;" data-options="fit:true, border:false"> 
				<div title="首页">
					<h2>当前客户端系统信息</h2>

					<p id="pc_info" style="width: 100%;height: 100px;">
					</p>
					<div></div>
					<h2>服务器资源情况</h2>
					<pre style="margin:5px;line-height:1.4em">
					CPU个数:<font id="cpu_cout"><%=Runtime.getRuntime().availableProcessors() %>个</font>
					空闲内存:<font id="free_memory"><%=Runtime.getRuntime().freeMemory()/1024/1024 %>M</font>
					总内存:<font id="total_memory"><%=Runtime.getRuntime().totalMemory()/1024/1024 %>M</font>
					最大可用内存:<font id="max_memory"><%=Runtime.getRuntime().maxMemory()/1024/1024 %>M</font>
					</pre>
				</div>
			</div>
		</div>

	</body>


</html>
